home *** CD-ROM | disk | FTP | other *** search
/ CD Actual 44 / PC Actual CD 44.iso / Linux / Cygwin / full.exe / Disk1 / data1.cab / Tools / H-i586-cygwin32 / i586-cygwin32 / include / sys / errno.h < prev    next >
Encoding:
C/C++ Source or Header  |  1998-12-04  |  5.2 KB  |  146 lines

  1. /* errno is not a global variable, because that would make using it
  2.    non-reentrant.  Instead, its address is returned by the function
  3.    __errno.  */
  4.  
  5. #ifndef _SYS_ERRNO_H_
  6. #ifdef __cplusplus
  7. extern "C" {
  8. #endif
  9. #define _SYS_ERRNO_H_
  10.  
  11. #include <sys/reent.h>
  12.  
  13. #ifndef _REENT_ONLY
  14. #define errno (*__errno())
  15. extern int *__errno _PARAMS ((void));
  16. #endif
  17.  
  18. #define __errno_r(ptr) ((ptr)->_errno)
  19.  
  20. #define    EPERM 1        /* Not super-user */
  21. #define    ENOENT 2    /* No such file or directory */
  22. #define    ESRCH 3        /* No such process */
  23. #define    EINTR 4        /* Interrupted system call */
  24. #define    EIO 5        /* I/O error */
  25. #define    ENXIO 6        /* No such device or address */
  26. #define    E2BIG 7        /* Arg list too long */
  27. #define    ENOEXEC 8    /* Exec format error */
  28. #define    EBADF 9        /* Bad file number */
  29. #define    ECHILD 10    /* No children */
  30. #define    EAGAIN 11    /* No more processes */
  31. #define    ENOMEM 12    /* Not enough core */
  32. #define    EACCES 13    /* Permission denied */
  33. #define    EFAULT 14    /* Bad address */
  34. #define    ENOTBLK 15    /* Block device required */
  35. #define    EBUSY 16    /* Mount device busy */
  36. #define    EEXIST 17    /* File exists */
  37. #define    EXDEV 18    /* Cross-device link */
  38. #define    ENODEV 19    /* No such device */
  39. #define    ENOTDIR 20    /* Not a directory */
  40. #define    EISDIR 21    /* Is a directory */
  41. #define    EINVAL 22    /* Invalid argument */
  42. #define    ENFILE 23    /* Too many open files in system */
  43. #define    EMFILE 24    /* Too many open files */
  44. #define    ENOTTY 25    /* Not a typewriter */
  45. #define    ETXTBSY 26    /* Text file busy */
  46. #define    EFBIG 27    /* File too large */
  47. #define    ENOSPC 28    /* No space left on device */
  48. #define    ESPIPE 29    /* Illegal seek */
  49. #define    EROFS 30    /* Read only file system */
  50. #define    EMLINK 31    /* Too many links */
  51. #define    EPIPE 32    /* Broken pipe */
  52. #define    EDOM 33        /* Math arg out of domain of func */
  53. #define    ERANGE 34    /* Math result not representable */
  54. #define    ENOMSG 35    /* No message of desired type */
  55. #define    EIDRM 36    /* Identifier removed */
  56. #define    ECHRNG 37    /* Channel number out of range */
  57. #define    EL2NSYNC 38    /* Level 2 not synchronized */
  58. #define    EL3HLT 39    /* Level 3 halted */
  59. #define    EL3RST 40    /* Level 3 reset */
  60. #define    ELNRNG 41    /* Link number out of range */
  61. #define    EUNATCH 42    /* Protocol driver not attached */
  62. #define    ENOCSI 43    /* No CSI structure available */
  63. #define    EL2HLT 44    /* Level 2 halted */
  64. #define    EDEADLK 45    /* Deadlock condition */
  65. #define    ENOLCK 46    /* No record locks available */
  66. #define EBADE 50    /* Invalid exchange */
  67. #define EBADR 51    /* Invalid request descriptor */
  68. #define EXFULL 52    /* Exchange full */
  69. #define ENOANO 53    /* No anode */
  70. #define EBADRQC 54    /* Invalid request code */
  71. #define EBADSLT 55    /* Invalid slot */
  72. #define EDEADLOCK 56    /* File locking deadlock error */
  73. #define EBFONT 57    /* Bad font file fmt */
  74. #define ENOSTR 60    /* Device not a stream */
  75. #define ENODATA 61    /* No data (for no delay io) */
  76. #define ETIME 62    /* Timer expired */
  77. #define ENOSR 63    /* Out of streams resources */
  78. #define ENONET 64    /* Machine is not on the network */
  79. #define ENOPKG 65    /* Package not installed */
  80. #define EREMOTE 66    /* The object is remote */
  81. #define ENOLINK 67    /* The link has been severed */
  82. #define EADV 68        /* Advertise error */
  83. #define ESRMNT 69    /* Srmount error */
  84. #define    ECOMM 70    /* Communication error on send */
  85. #define EPROTO 71    /* Protocol error */
  86. #define    EMULTIHOP 74    /* Multihop attempted */
  87. #define    ELBIN 75    /* Inode is remote (not really error) */
  88. #define    EDOTDOT 76    /* Cross mount point (not really error) */
  89. #define EBADMSG 77    /* Trying to read unreadable message */
  90. #define ENOTUNIQ 80    /* Given log. name not unique */
  91. #define EBADFD 81    /* f.d. invalid for this operation */
  92. #define EREMCHG 82    /* Remote address changed */
  93. #define ELIBACC 83    /* Can't access a needed shared lib */
  94. #define ELIBBAD 84    /* Accessing a corrupted shared lib */
  95. #define ELIBSCN 85    /* .lib section in a.out corrupted */
  96. #define ELIBMAX 86    /* Attempting to link in too many libs */
  97. #define ELIBEXEC 87    /* Attempting to exec a shared library */
  98. #define ENOSYS 88    /* Function not implemented */
  99. #define ENMFILE 89      /* No more files */
  100. #define ENOTEMPTY 90    /* Directory not empty */
  101. #define ENAMETOOLONG 91    /* File or path name too long */
  102. #define ELOOP 92    /* Too many symbolic links */
  103. #define EOPNOTSUPP 95    /* Operation not supported on transport endpoint */
  104. #define EPFNOSUPPORT 96 /* Protocol family not supported */
  105. #define ECONNRESET 104  /* Connection reset by peer */
  106. #define ENOBUFS 105    /* No buffer space available */
  107. #define EAFNOSUPPORT 106
  108. #define EPROTOTYPE 107
  109. #define ENOTSOCK 108
  110. #define ENOPROTOOPT 109
  111. #define ESHUTDOWN 110
  112. #define ECONNREFUSED 111    /* Connection refused */
  113. #define EADDRINUSE 112        /* Address already in use */
  114. #define ECONNABORTED 113    /* Connection aborted */
  115. #define ENETUNREACH 114
  116. #define ENETDOWN 115
  117. #define ETIMEDOUT 116
  118. #define EHOSTDOWN 117
  119. #define EHOSTUNREACH 118
  120. #define EINPROGRESS 119
  121. #define EALREADY 120
  122. #define EDESTADDRREQ 121
  123. #define EMSGSIZE 122
  124. #define EPROTONOSUPPORT 123
  125. #define ESOCKTNOSUPPORT 124
  126. #define EADDRNOTAVAIL 125
  127. #define ENETRESET 126
  128. #define EISCONN 127
  129. #define ENOTCONN 128
  130. #define ETOOMANYREFS 129
  131. #define EPROCLIM 130
  132. #define EUSERS 131
  133. #define EDQUOT 132
  134. #define ESTALE 133
  135. #define ENOTSUP 134
  136.  
  137. /* From cygwin32.  */
  138. #define EWOULDBLOCK EAGAIN    /* Operation would block */
  139.  
  140. #define __ELASTERROR 2000    /* Users can add values starting here */
  141.  
  142. #ifdef __cplusplus
  143. }
  144. #endif
  145. #endif /* _SYS_ERRNO_H */
  146.